package SV_EXEC;
import javax.servlet.*;
import java.io.IOException;

public class Vulnerable_01 {
    public void checkHost(ServletRequest req) throws IOException {
        // Source of data from HTTP request in servlet
        String hostName = req.getParameter("userHostName");
        String command = "nslookup " + hostName;
        Process proc = Runtime.getRuntime().exec(command);
        // ...
    }

}
